using System.Collections.Generic;
using System.Data;
using System.Threading.Tasks;

namespace HDLogCenter.Infrastructure.Mysql
{ 
    public interface IDbService
    {
        IDbConnection GetConnection();
        Task<T> QuerySingleOrDefaultAsync<T>(string sql, object param = null);
        Task<IEnumerable<T>> QueryAsync<T>(string sql, object param = null);
        Task<int> ExecuteAsync(string sql, object param = null);
        Task<long> ExecuteScalarAsync(string sql, object param = null);
    }
}

